package gui_classes;

import java.awt.Dimension;

import javax.swing.JPanel;

import domain.User;

public class ViewUserPage extends DERPBase {
	
	private User usr;
	private UsersPagePanel userinfo;
//	private ViewingPatientPanel vpanel;
	
	private DERPBase callingPage;

	/**
	 * Create the panel.
	 */
	public ViewUserPage(User usr, DERPBase page ) {

	//	setLayout(new BorderLayout());
		setPreferredSize(new Dimension(600,510));
		
		this.usr = usr;
		this.callingPage = page;
		
		userinfo = new UsersPagePanel(usr);
		
//		add(userinfo, BorderLayout.NORTH);
		add(userinfo);
		
		GUI_Main.getFrame().setTitle("Looking at User " + usr.getName());
		
	}
	
	public void display()
	{
		GUI_Main.replacePanel(this);
	}

}
